package com.wl.designpattern.flyweight;

/**
 * Created by wangliang on 2021/2/27.
 */
public class ShareBike implements IBike {

    private int price = 1;//单价
    private int total;//总价

    @Override
    public void billing(int time) {
        total = price * time;
        System.out.println("骑车花费了" + total + "元");
    }
}
